package com.example.high_slope_electronic_sand_table.deviceStatus.controller;

import com.example.high_slope_electronic_sand_table.deviceStatus.dto.RadarDeviceStatusDTO;
import com.example.high_slope_electronic_sand_table.deviceStatus.service.RadarDeviceStatusService;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.tags.Tag;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * 雷达设备状态信息
 */
@Tag(name = "雷达设备状态信息")
@RestController
@RequestMapping(value = "/high-slope")
public class RadarDeviceStatusController {
    // 查询雷达设备状态信息，提供一个接口，每次查询都是不一样的值，不需要提供设备ID等参数

    @Autowired
    private RadarDeviceStatusService radarDeviceStatusService;

    /**
     * 查询雷达设备状态信息
     *
     * @return
     */
    @Operation(summary = "查询雷达设备状态信息")
    @GetMapping(value = "/device-status/radar")
    public RadarDeviceStatusDTO getRadarDeviceStatus() {
        return radarDeviceStatusService.getRadarDeviceStatus();
    }
}
